<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
    <th:block th:include="common/include :: header('收货人列表')"/>
</head>
<body class="gray-bg">
<div class="container-div">
    <div class="row">
        <div class="col-sm-12 search-collapse">
            <form id="customer-form">
                <div class="select-list">
                    <ul>
                        <li>
                            关键字：<input type="text" name="keyword" placeholder="模糊查询用户名/姓名"/>
                        </li>
                        <li>
                            手机号码：<input type="number" name="consigneeMobile"/>
                        </li>
                        <li>
                            <a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i
                                    class="fa fa-search"></i>&nbsp;搜索</a>
                            <a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i
                                    class="fa fa-refresh"></i>&nbsp;重置</a>
                        </li>
                    </ul>
                </div>
            </form>
        </div>
        <div class="col-sm-12 select-table table-striped">
            <table id="bootstrap-table"></table>
        </div>
    </div>
</div>
<th:block th:include="common/include :: footer"/>
<script th:inline="javascript">

    var removeFlag = [[${@permission.hasPermi('business:consignees:remove')}]];
    var editFlag = [[${@permission.hasPermi('business:consignees:edit')}]];
    var prefix = ctx + "/business/consignees";
    $(function () {
        var options = {
            url: prefix + "/query",
            uniqueId: 'id',
            modalName: "收货人",
            columns: [{
                checkbox: true
            },
                {
                    field: 'id',
                    title: '编号',
                    visible: false
                },
                {
                    field: 'username',
                    title: '用户名'
                },
                {
                    field: 'consigneeName',
                    title: '姓名'
                },
                {
                    field: 'consigneeMobile',
                    title: '手机号码'
                },
                {
                    field: 'universityName',
                    title: '学校'
                },
                {
                    field: 'campusName',
                    title: '校区'
                },
                {
                    field: 'detailInfo',
                    title: '详细地址'
                },
                {
                    field: 'isDefault',
                    title: '默认状态',
                    formatter: function (value, row, index) {
                        return value ? '是' : '否';
                    }
                }
            ]
        };
        $.table.init(options);
    });
</script>
</body>
</html>